<?php if (!defined('THINK_PATH')) exit();?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
    <title>Pour un Sourire Eternel(PSE)  </title>
    <link rel="stylesheet" href="__APP__/Public/css/common.css" type="text/css" />
    <link rel="stylesheet" href="__APP__/Public/css/public.css" type="text/css" />
    <link rel='stylesheet' href='__APP__/Public/css/jquery-ui.css' type='text/css' >
    
	<script type="text/javascript" src="__APP__/Public/js/jquery-1.5.1.min.js"></script>
	<script type="text/javascript" src="__APP__/Public/js/jquery-ui-1.8.11.min.js"></script>
	<script type="text/javascript" src="__APP__/Public/js/functions.js"></script>
</head>
<body>
    <!--header开始-->
    <div id="header" class="header">
        <a href="#" class="logo"></a>
        <span style="float:right;margin-top: 26px;"><?php echo L('header_tag1');?><br /><?php echo L('header_tag2');?></span> 
    </div>
    <!--header结束-->


    <div class="container02">
        <div class="main">
            <div class="left userinformation">
                <h3><?php echo (L("basic_info")); ?></h3>
  				<form id='form1' method="post" action='/Users/doAddBasicUserInfo'>           
                <table>
                    <tr>
                        <td class="tar">*<?php echo (L("email")); ?>: &nbsp;&nbsp;</td>
                        <td><input type="text" class="input02" name='email' /></td>
                    </tr>
                    <tr>
                        <td class="tar">*<?php echo (L("password")); ?>: &nbsp;&nbsp;</td>
                        <td><input type="password" class="input02" name='password' /></td>
                    </tr>
                    <tr>
                        <td class="tar"><?php echo (L("firstname")); ?>: &nbsp;&nbsp;</td>
                        <td><input type="text" class="input02" name='firstname'/></td>
                    </tr>
                    <tr>
                        <td class="tar"><?php echo (L("secondname")); ?>: &nbsp;&nbsp;</td>
                        <td><input type="text" class="input02" name='secondname'/></td>
                    </tr>
                    <tr>
                        <td class="tar"><?php echo (L("lastname")); ?>: &nbsp;&nbsp;</td>
                        <td><input type="text" class="input02" name='lastname'/></td>
                    </tr>
                    <tr>
                        <td class="tar"><?php echo (L("user_gender")); ?>: &nbsp;&nbsp;</td>
                        <td>
                            <select name="gender">
								<option value="0"><?php echo (L("female")); ?></option>
								<option value="1" selected='selected'><?php echo (L("male")); ?></option>
							</select>
                        </td>
                    </tr>
                    <tr>
                        <td class="tar"><?php echo (L("birthday")); ?>: &nbsp;&nbsp;</td>
                        <td><input id='birthday' name='birthday' readonly="readonly"  type="text" class='input02'/></td>
                    </tr>
                    <tr>
                        <td class="tar"><?php echo (L("deathday")); ?>: &nbsp;&nbsp;</td>
                        <td><input id='deathday' name='deathday' readonly='readonly' type="text" class="input02" /></td>
                    </tr>
                    <tr>
                        <td class="tar"><?php echo (L("avatar")); ?>: &nbsp;&nbsp;</td>
                        <td>
                            <div id="avatarImageDiv" style="width:200px;height:200px;background-color: #F1F1F1;"></div>
                        	<input id="uploadAvatar" type="button" value="<?php echo (L("upload_avatar")); ?>"/>
                        	<span><?php echo (L("avatar_max_size")); ?></span>
                        	<input id="hidAvatar" name="hidAvatar" type="hidden" /> 
                        </td>
                    </tr>
					

                    <tr class='relation'>
                        <td class="tar"><?php echo (L("relationship")); ?>: &nbsp;&nbsp;</td>
                        <td>
                        	<input name="relationship" type="checkbox" checked="checked" value="1"/><?php echo (L("family")); ?>
							<input name="relationship" type="checkbox" value="2"/><?php echo (L("friend")); ?>
						</td>
                    </tr>
                    <tr class='chkvisiable'>
                        <td class="tar"><?php echo (L("access_auth")); ?>: &nbsp;&nbsp;</td>
                        <td>
							<input id="chkboxPrivate" name="visiable" type="checkbox" checked="checked" value="0"/><?php echo (L("auth_private")); ?>
							<input id="chkboxSemiPublic" name="visiable" type="checkbox" value="1"/><?php echo (L("auth_semi_public")); ?>
							<input id="chkboxPublic" name="visiable" type="checkbox"  value="2"/><?php echo (L("auth_public")); ?>
                        </td>
                    </tr>
                    <tr id='accesspwdTr'>
                        <td class="tar"><?php echo (L("access_pwd")); ?>: &nbsp;&nbsp;</td>
                        <td><input id="accesspwd" type="password" class="input02" name="accesspwd" /></td>
                    </tr>
                    <tr id='pwdhintTr'>
                        <td class="tar"><?php echo (L("pwd_hint")); ?>: &nbsp;&nbsp;</td>
                        <td><input id="pwdhint" type="text" class="input02" name="pwdhint" /></td>
                    </tr>
                    <tr>
                        <td colspan="2" class="tac">
                            <a href="javascript:$('#form1').submit();" class="contactbtn"><?php echo (L("submit")); ?></a>
                        	<a href="javascript:goback('/Users/userProfile?uid=');" class="contactbtn"><?php echo (L("goback")); ?></a>
                        </td>
                    </tr>
                </table>
            	</form>
            	<div id="dialog-set-avatar" style="display: none;">
	            	<script>
						var thumbPrefix = 'avatar_w200_w200_';
						var thumbW = 200;
						var thumbH = 200;
					</script>
				    <script type="text/javascript" src="__APP__/Public/js/ajaxFileUpload.js"></script>
<div>
	<input type="file" id="aFile" name="aFile" onchange="uploadImg();"/>
	<div id="imgThumbDiv" style="width:200px;height: 200px;background-color: #F8F3F3"></div>
	<input type="button" value="<?php echo (L("ok")); ?>" onclick="uploadOk();"/>
	<input type="button" value="<?php echo (L("cancel")); ?>" onclick="closeDialog();" />
</div>
<script>
	var imgName = "";
	function uploadImg() {
		$.ajaxFileUpload({
            url: '/Public/uploadImg',
            secureuri: false,
            fileElementId: 'aFile',
            data:{prefix:thumbPrefix,thumbW:thumbW,thumbH:thumbH},
            type:'json',
            success: function(data){
            	var obj = $.parseJSON(data);
            	if (obj.status == 1) {
            		imgName = "__ROOT__/Uploads/" + thumbPrefix + obj.imgName;
            		$('#imgThumbDiv').css('background', "url("+imgName+") no-repeat");
            	} else if(obj.status == 0) {
            		alert(obj.msg);
            	}
            	
            },
            error: function () {
                alert("<?php echo (L("upload_failed")); ?>");
            }
        });
	}
	function uploadOk() {
		if(window.OnImgUpload) {
			OnImgUpload(imgName);
		}
		closeDialog();
	}
	function closeDialog() {
		if(window.OnUploadDialogClose) {
			OnUploadDialogClose();
		}	
	}
</script>

				</div>
            
            </div>
            <div class="right desimg">
                <a href="#">
                    <img src="__APP__/Public/images/test03.jpg" /></a>
            </div>
            <div class="clear">
            </div>
        </div>
    </div>
<!--footer开始-->
    <div id="footer">
        <div class="main">
            <div class="left">
                <a href="#">Offrir un Sourire Eternel</a></div>
            
            <div class="left ml118">
                <a href="#">｜Qui sommes nous?</a> <a href="#">｜Mentions légales</a> <!-- <a href="/Public/contactUs">｜联系我们</a> -->
            </div>
            <div class="right">
            	<a href="/Public/FAQ">FAQ</a>
                </div>
            <div class="clear">
            </div>
        </div>
    </div>
    <!--footer结束-->
</body>
</html>